package com.example.hand_write_ipc;

import android.os.IBinder;
import android.os.IInterface;
import android.os.RemoteException;

import com.example.ipc.Book;

import java.util.List;

public interface IBookManager extends IInterface {

    String DESCRIPTOR = "com.example.ipc.IBookManager";

    int TRANSACTION_getBookList = IBinder.FIRST_CALL_TRANSACTION;
    int TRANSACTION_addBook = IBinder.FIRST_CALL_TRANSACTION + 1;
    int TRANSACTION_addBookListener = IBinder.FIRST_CALL_TRANSACTION + 2;

    List<Book> getBookList() throws RemoteException;

    void addBook(Book book) throws RemoteException;

    void addBookListener(IBookListener listener) throws RemoteException;
}
